package com.example.springbootdemo.mall.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonIgnore;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.Date;

/**
 *@author xuwangqi
 *@date 2021/5/24 9:28
 **/
/**
    * 商品订单明细
    */
@ApiModel(value="com-example-springbootdemo-entity-OrderProductItem")
@TableName(value = "order_product_item")
@Data
public class OrderProductItem {
    @TableId(value = "id", type = IdType.AUTO)
    @ApiModelProperty(value="")
    private Long id;

    /**
     * 总订单id
     */
    @TableField(value = "order_id")
    @ApiModelProperty(value="总订单id")
    private String orderId;

    /**
     * 总订单编号
     */
    @TableField(value = "order_no")
    @ApiModelProperty(value="总订单编号")
    private String orderNo;

    /**
     * 用户id
     */
    @TableField(value = "user_id")
    @ApiModelProperty(value="用户id")
    private Long userId;

    /**
     * 商品id
     */
    @TableField(value = "product_id")
    @ApiModelProperty(value="商品id")
    private Long productId;

    /**
     * 导游id
     */
    @TableField(value = "guide_id")
    @ApiModelProperty(value="导游id")
    private Long guideId;

    /**
     * sku_id
     */
    @TableField(value = "sku_id")
    @ApiModelProperty(value="sku_id")
    private Long skuId;

    /**
     * 优惠券码
     */
    @TableField(value = "coupon_code")
    @ApiModelProperty(value="优惠券码")
    private String couponCode;

    /**
     * 优惠券抵扣金额
     */
    @TableField(value = "coupon_amount")
    @ApiModelProperty(value="优惠券抵扣金额")
    private BigDecimal couponAmount;

    /**
     * 导游分成比例
     */
    @TableField(value = "guide_proportion")
    @ApiModelProperty(value="导游分成比例")
    private BigDecimal guideProportion;

    /**
     * sku分成比例
     */
    @TableField(value = "sku_proportion")
    @ApiModelProperty(value="sku分成比例")
    private BigDecimal skuProportion;

    /**
     * 商品编码
     */
    @TableField(value = "inner_sn")
    @ApiModelProperty(value="商品编码")
    private String innerSn;

    /**
     * 第三方编码
     */
    @TableField(value = "outer_sn")
    @ApiModelProperty(value="第三方编码")
    private String outerSn;

    /**
     * 商品标题
     */
    @TableField(value = "product_title")
    @ApiModelProperty(value="商品标题")
    private String productTitle;

    /**
     * 商品图片
     */
    @TableField(value = "product_cover")
    @ApiModelProperty(value="商品图片")
    private String productCover;

    /**
     * 商品规格
     */
    @TableField(value = "product_standard")
    @ApiModelProperty(value="商品规格")
    private String productStandard;

    /**
     * 供应商id
     */
    @TableField(value = "supplier_id")
    @ApiModelProperty(value="供应商id")
    private Long supplierId;

    /**
     * 运费
     */
    @TableField(value = "freight")
    @ApiModelProperty(value="运费")
    private BigDecimal freight;

    /**
     * 数量
     */
    @TableField(value = "quantity")
    @ApiModelProperty(value="数量")
    private Integer quantity;

    /**
     * 订单商品单价
     */
    @TableField(value = "product_price")
    @ApiModelProperty(value="订单商品单价")
    private BigDecimal productPrice;

    /**
     * 是否结算了导游分成 0 未结算 1 已结算
     */
    @TableField(value = "settlement_share_price")
    @ApiModelProperty(value="是否结算了导游分成 0 未结算 1 已结算")
    private Boolean settlementSharePrice;

    /**
     * 订单导游分成金额
     */
    @TableField(value = "share_price")
    @ApiModelProperty(value="订单导游分成金额")
    private BigDecimal sharePrice;

    /**
     * 订单详情总价格(去除掉优惠)
     */
    @TableField(value = "total_amount")
    @ApiModelProperty(value="订单详情总价格(去除掉优惠)")
    private Integer totalAmount;

    /**
     * 付款金额
     */
    @TableField(value = "pay_amount")
    @ApiModelProperty(value="付款金额")
    private BigDecimal payAmount;

    /**
     * 支付方式
     */
    @TableField(value = "payment_type")
    @ApiModelProperty(value="支付方式")
    private String paymentType;

    /**
     * 支付时间
     */
    @TableField(value = "gmt_pay")
    @ApiModelProperty(value="支付时间")
    @JsonFormat( pattern = "yyyy-MM-dd HH:mm:ss")
   private LocalDateTime gmtPay;

    /**
     * 退款id
     */
    @TableField(value = "refund_id")
    @ApiModelProperty(value="退款id")
    private Long refundId;

    /**
     * 退货id
     */
    @TableField(value = "reship_id")
    @ApiModelProperty(value="退货id")
    private Long reshipId;

    /**
     * 状态0->待付款；4->已付款；6->第三方确认有货 9-> 第三方确认无货  12->待发货；16->已发货；20 ->已取消(未付款取消和付款取消和已发货取消); 24已确认（确认收货）; 28->已完成；32->已关闭；
     */
    @TableField(value = "status")
    @ApiModelProperty(value="状态0->待付款；4->已付款；6->第三方确认有货 9-> 第三方确认无货  12->待发货；16->已发货；20 ->已取消(未付款取消和付款取消和已发货取消); 24已确认（确认收货）; 28->已完成；32->已关闭；")
    private Byte status;

    /**
     * 定制需求(比如要刻什么字)
     */
    @TableField(value = "customize")
    @ApiModelProperty(value="定制需求(比如要刻什么字)")
    private String customize;

    /**
     * 物流id
     */
    @TableField(value = "logistic_no")
    @ApiModelProperty(value="物流id")
    private String logisticNo;

    /**
     * 物流公司
     */
    @TableField(value = "logistic_name")
    @ApiModelProperty(value="物流公司")
    private String logisticName;

    /**
     * 物流代码
     */
    @TableField(value = "logistic_code")
    @ApiModelProperty(value="物流代码")
    private String logisticCode;

    /**
     * 关闭原因
     */
    @TableField(value = "closed_reason")
    @ApiModelProperty(value="关闭原因")
    private String closedReason;

    /**
     * 关闭时间
     */
    @TableField(value = "gmt_close")
    @ApiModelProperty(value="关闭时间")
    @JsonFormat( pattern = "yyyy-MM-dd HH:mm:ss")
   private LocalDateTime gmtClose;

    /**
     * 发货时间
     */
    @TableField(value = "gmt_delivery")
    @ApiModelProperty(value="发货时间")
    @JsonFormat( pattern = "yyyy-MM-dd HH:mm:ss")
   private LocalDateTime gmtDelivery;

    /**
     * 确认收货时间
     */
    @TableField(value = "gmt_receive")
    @ApiModelProperty(value="确认收货时间")
    @JsonFormat( pattern = "yyyy-MM-dd HH:mm:ss")
   private LocalDateTime gmtReceive;

    @TableField(value = "gmt_create")
    @ApiModelProperty(value="")
    @JsonFormat( pattern = "yyyy-MM-dd HH:mm:ss")
   private LocalDateTime gmtCreate;

    @TableField(value = "gmt_modified")
    @ApiModelProperty(value="")
    @JsonIgnore
   private LocalDateTime gmtModified;

    @TableField(value = "gmt_delete")
    @ApiModelProperty(value="")
    @JsonIgnore
   private LocalDateTime gmtDelete;

    @TableField(value = "is_delete")
    @ApiModelProperty(value="")
    private Byte isDelete;
}